<template>
  <el-container class="home_container" style="margin-bottom: 30px;">
    <!--     头部区域 -->
    <el-header>
      <div >
        <img src="../assets/gouwuche.png" alt="" style="width: 20px;height: 20px;margin-left: 30px">
        <span style="margin-left: 30px">超市管理系统</span>
      </div>
      <div>
<!--        <el-tooltip content="菜单" placement="bottom" effect="light">-->
<!--          <img src="../assets/caidan.png" alt="" style="width: 20px;height: 20px;margin-right: 30px" @click="toEmployee">-->
<!--        </el-tooltip>-->
        <el-tooltip content="登录" placement="bottom" effect="light">
          <img src="../assets/touxiang.png" alt="" style="width: 20px;height: 20px;margin-right: 30px" @click="loginout">
        </el-tooltip>
<!--        <el-tooltip content="退出账户" placement="bottom" effect="light">-->
<!--          <img src="../assets/tuichu.png" alt="" style="width: 20px;height: 20px;margin-right: 30px" @click="loginout">-->
<!--        </el-tooltip>-->
      </div>
    </el-header>
      <router-view></router-view>
  </el-container>
</template>
<script>
export default {
  name: 'Header',
  methods: {
    loginout () {
      this.$router.push('/login')
    },
    toHome () {
      this.isCollapse = true
      this.$router.push('/header')
    },
    toEmployee () {
      this.isCollapse = false
      this.$router.push('/employees')
    },
    toAccounts () {
      this.isCollapse = true
      this.$router.push('/accounts')
    }
  }
}
</script>

<style scoped lang="less">
.el-header {
  background-color: red;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-left: 0;
  span {
    color: #fff;
    font-size: 20px;
  }
  div {
    display: flex;
    align-items: center;
  }
}
span {
  margin-left: 15px;
}
.el-aside {
  border-right: none;
}
.el-menu {
  border-right: none;
}
.el-main {
  background-color: #eaedf1;
}
.iconfont {
  margin-right: 10px;
}
.toggle-button {
  background-color: #FFFFFF;
  font-size: 10px;
  line-height: 24px;
  color: #fff;
  text-align: center;
  letter-spacing: 0.2em;
  // 鼠标放上面变成一个小手
  cursor: pointer;
}
</style>
